<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Dashboard Template for Bootstrap</title>

    <!-- Bootstrap core CSS -->
    <link th:href="@{/css/bootstrap.min.css}" rel="stylesheet">

    <!-- Custom styles for this template -->
    <link th:href="@{/css/dashboard.css}" rel="stylesheet">

    <!--侧边栏-->
    <link th:href="@{/assets/dist/css/bootstrap.min.css}" rel="stylesheet">
    <link th:href="@{/assets/sidebars/sidebars.css}" rel="stylesheet">
    <script th:src="@{/assets/dist/js/bootstrap.bundle.min.js}"></script>

   <style>

   </style>

</head>

<body>

<!--插入头部-->
<div th:replace="~{commons/commons::top_bar}"></div>


<div class="container-fluid">
    <div class="row">

        <!--插入侧边导航-->
        <div th:replace="~{commons/commons::side_bar(active='ast_controller_register_list.html')}"></div>

        <main role="main" class="col-md-9 ml-sm-auto col-lg-10 pt-3 px-4">
            <h5 >设备端注册-列表</h5>
            <!--筛选框-->
            <form class="form-inline" th:action="@{/asset/getAstControllerRegistersByExample}" method="post">
                <div class="form-group">
                    <label for="exampleInputName2">设备编码</label>
                    <input type="text" class="form-control" name="device_code" th:value="${device_code}">
                </div>
                <div class="form-group">
                    <label for="exampleInputName2">消息版本号</label>
                    <input type="text" class="form-control" name="ver" th:value="${ver}">
                </div>
                <button type="submit" class="btn btn-sm btn-success">搜索</button>
            </form>

            <!--从请求中得到东西进行遍历-->
            <div class="table-responsive">
                <table class="table text-nowrap table-sm">
                    <thead>
                    <tr>
                        <th>操作</th>
                        <th>设备编码</th>
                        <th>cmd</th>
                        <th>消息版本号</th>
                        <th>设备端IMEI</th>
                        <th>行政区划编码</th>
                        <th>记录时间</th>
                        <th hidden="false">id</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr th:each="data:${datas}">
                        <td>
                            <a class="btn btn-sm btn-primary"
                               th:href="@{'/asset/getAstControllerRegisterById/'+${data.getAst_controller_register_id()}}">表单</a>
                        </td>
                        <td th:text="${data.getDevice_code()}"></td>
                        <td th:text="${data.getCmd()}"></td>
                        <td th:text="${data.getVer()}"></td>
                        <td th:text="${data.getImei()}"></td>
                        <td th:text="${data.getZone_code()}"></td>
                        <td th:text="${#dates.format(data.getCreate_time(),'yyyy-MM-dd HH:mm:ss')}"></td>
                        <td hidden="false" th:text="${data.getAst_controller_register_id()}"></td>
                    </tr>
                    </tbody>
                </table>
            </div>
        </main>
    </div>
</div>

    <script>

    </script>

</body>

</html>